<!DOCTYPE HTML>
<html>
<head>
    <title>二手电子乐园 - 中国领先的二手电子产品信息服务平台</title>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
    <link rel="stylesheet" href="assets/css/main.css" />
</head>
<body class="homepage is-preload">
    <div id="page-wrapper">

        <!-- Header -->
        <div id="header-container"></div>

        <!-- Hero -->
        <section id="hero" class="container">
            <header>
                <h2>二手电子乐园 - 中国领先的<br />
                二手电子产品信息服务平台</h2>
            </header>
            <p>专业的二手电子产品信息展示平台，为您提供安全、透明、便捷的二手交易信息服务<br />
            严格审核卖家信息，保障买家权益，打造诚信的二手交易环境</p>
            <ul class="actions">
                <li><a href="category.html?type=phone" class="button">立即浏览</a></li>
                <li><a href="vip.html" class="button alt">了解VIP特权</a></li>
            </ul>
        </section>

        <!-- Features 1 - 精选产品 -->
        <div class="wrapper">
            <div class="container">
                <div class="row" v-scope>
                    <section class="col-6 col-12-narrower feature" v-for="product in featured.slice(0, 2)" :key="product.id">
                        <div class="image-wrapper first">
                            <a :href="'product-detail.html?id=' + product.id" class="image featured first">
                                <img :src="product.image" :alt="product.title" />
                            </a>
                        </div>
                        <header>
                            <h2>{{ product.title }}</h2>
                        </header>
                        <p>{{ product.description }}</p>
                        <p><strong>价格：¥{{ product.price }}</strong></p>
                        <ul class="actions">
                            <li><a :href="'product-detail.html?id=' + product.id" class="button">查看详情</a></li>
                        </ul>
                    </section>
                </div>
            </div>
        </div>

        <!-- Promo -->
        <div id="promo-wrapper">
            <section id="promo">
                <h2>品质保证 · 诚信交易 · 专业服务</h2>
                <a href="category.html" class="button">浏览全部商品</a>
            </section>
        </div>

        <!-- Features 2 - 推荐产品 -->
        <div class="wrapper">
            <section class="container">
                <header class="major">
                    <h2>热门推荐</h2>
                    <p>精选优质二手电子产品，品质保证，价格实惠</p>
                </header>
                <div class="row features" v-scope>
                    <section class="col-4 col-12-narrower feature" v-for="product in recommended" :key="product.id">
                        <div class="image-wrapper">
                            <a :href="'product-detail.html?id=' + product.id" class="image featured">
                                <img :src="product.image" :alt="product.title" />
                            </a>
                        </div>
                        <header>
                            <h3>{{ product.title }}</h3>
                        </header>
                        <p>{{ product.description }}</p>
                        <p><strong>价格：¥{{ product.price }}</strong></p>
                        <ul class="actions">
                            <li><a :href="'product-detail.html?id=' + product.id" class="button small">查看详情</a></li>
                        </ul>
                    </section>
                </div>
                <ul class="actions major">
                    <li><a href="category.html" class="button">查看更多商品</a></li>
                </ul>
            </section>
        </div>

        <!-- Footer -->
        <div id="footer-container"></div>

    </div>

    <!-- Scripts -->
    <script src="utils/loader.js"></script>
    <script>
        // 等待脚本加载完成
        window.addEventListener('scriptsLoaded', function() {
            // 加载公共组件
            $('#header-container').load('header.html');
            $('#footer-container').load('footer.html');

            // 初始化 petite-vue
            PetiteVue.createApp({
                featured: window.siteData.featuredProducts || [],
                recommended: window.siteData.recommendedProducts || []
            }).mount('[v-scope]');
        });
    </script>
</body>
</html>